home *** CD-ROM | disk | FTP | other *** search
/ Microsoft Home CD Sampler / Microsoft Home CD Sampler.iso / multi / wrldatls / atlsdata.dxr / 00151.ls < prev    next >
Encoding:
Text File  |  1995-09-12  |  2.8 KB  |  129 lines

  1. on startMovie
  2.   global mainPath
  3.   set the centerStage to 1
  4.   set the exitLock to 0
  5.   set the stageColor to 255
  6.   set mainPath to pathName()
  7. end
  8.  
  9. on pressOn
  10.   global lastClickOn
  11.   puppetSound(0)
  12.   set whichSprite to the clickOn
  13.   puppetSprite(whichSprite, 1)
  14.   puppetTransition(0)
  15.   set lastClickOn to whichSprite
  16.   set tempHor to the locH of sprite (whichSprite + 2)
  17.   set the locH of sprite (whichSprite + 2) to the locH of sprite whichSprite
  18.   puppetSound("clickSound")
  19.   updateStage()
  20.   repeat while the stillDown
  21.     if rollOver(whichSprite + 5) then
  22.       next repeat
  23.     end if
  24.     set the locH of sprite (whichSprite + 2) to tempHor
  25.     puppetSound("clickSound")
  26.     updateStage()
  27.     puppetSprite(whichSprite, 0)
  28.     updateStage()
  29.     exit
  30.   end repeat
  31.   set the locH of sprite (whichSprite + 2) to tempHor
  32.   puppetSound("clickSound")
  33.   puppetSprite(whichSprite, 0)
  34.   updateStage()
  35.   updateStage()
  36.   puppetSound(0)
  37. end
  38.  
  39. on waitFor seconds
  40.   set now to the timer
  41.   repeat while the timer < (now + (seconds * 60))
  42.     if the mouseDown then
  43.       exit
  44.     end if
  45.   end repeat
  46. end
  47.  
  48. on waitSound thisone
  49.   updateStage()
  50.   if soundBusy(1) = 0 then
  51.     go(the frame + 1)
  52.   else
  53.     go(the frame)
  54.   end if
  55. end
  56.  
  57. on findAVI
  58.   openXLib("winInfo.dll")
  59.   set XAVI to winInfo(mnew)
  60.   set winDir to XAVI(mWindowsDirectory)
  61.   set sysDir to XAVI(mSystemDirectory)
  62.   set thereturn to 1
  63.   if not askForFile(winDir & "\msvideo.dll") then
  64.     if not askForFile(sysDir & "\msvideo.dll") then
  65.       set thereturn to 0
  66.     end if
  67.   end if
  68.   put thereturn
  69.   XAVI(mdispose)
  70.   closeXLib("winInfo.dll")
  71.   return thereturn
  72. end
  73.  
  74. on askForFile theDest
  75.   openXLib("fileIO")
  76.   set Jay to FileIO(mnew, "read", theDest)
  77.   if Jay <> -43 then
  78.     set thereturn to 1
  79.   else
  80.     set thereturn to 0
  81.   end if
  82.   if Jay <> -43 then
  83.     Jay(mdispose)
  84.   end if
  85.   closeXLib("fileIO")
  86.   return thereturn
  87. end
  88.  
  89. on findCastMem theCastNum, theFrame, listMode
  90.   puppetTempo(100)
  91.   set inSequence to 0
  92.   set startFrame to 0
  93.   go(the lastFrame)
  94.   set lastFrame to the frame
  95.   if theFrame = 0 then
  96.     set theFrame to 1
  97.   end if
  98.   repeat while theFrame < (lastFrame + 1)
  99.     go(theFrame)
  100.     repeat with x = 1 to 48
  101.       if the castNum of sprite x = theCastNum then
  102.         if listMode = 0 then
  103.           beep()
  104.           exit
  105.         else
  106.           if listMode = 1 then
  107.             if inSequence = 1 then
  108.               set endFrame to the frame
  109.               exit repeat
  110.             else
  111.               set startFrame to the frame
  112.               set inSequence to 1
  113.               exit repeat
  114.             end if
  115.           end if
  116.         end if
  117.         next repeat
  118.       end if
  119.       if (x = 48) and (inSequence = 1) then
  120.         put "Castmember #" & theCastNum && "in frames" && startFrame && "to" && endFrame
  121.         set inSequence to 0
  122.       end if
  123.     end repeat
  124.     set theFrame to theFrame + 1
  125.   end repeat
  126.   beep()
  127.   beep()
  128. end
  129.